<#include "/freemarker/frame.ftl"> 
<@frame title="企业参数信息管理">
<script type="text/javascript" charset="utf-8">
		component.table.eidtRow=function(row_id){
				var row=$('#'+row_id);
				var cells=row.find('td');
				var pk = $(cells[1]).text();
				var src="mgr/enterprise/editParam!queryParamForEdit?pid="+pk;
				param={title:"系统参数修改",width:"800",height:"220",close:function(){window.location.reload()}};
				component.dialog.popDialog(src,param);
				
		};
		component.table.deletRow=function(row_id){
				var row=$('#'+row_id);
				var cells=row.find('td');
				var pk = $(cells[1]).text();
				var src="mgr/enterprise/editParam!deleteParam?pid="+pk
				param={title:"企业参数删除",width:"800",height:"220",close:function(){window.location.reload()}};
				component.dialog.popDialog(src,param);
		};
</script>
         <div class="contentcontainer">
            <div class="headings altheading">
                <h2>企业参数信息管理</h2>
            </div>
            <div class="contentbox">
     <@s.form action="addParam" method="get" namespace="/mgr/enterprise" theme="simple">
  						<table  class="input"><tr><td  class="label">
						<strong>描述:</strong> 
						</td><td>
						<@s.textfield cssClass="inputbox smallbox"  name="param.desc" label="描述" ></@s.textfield>
						</td><td  class="label">
						<strong>编码:</strong>
						</td><td>
						 <@s.textfield cssClass="inputbox smallbox" name="param.code" label="编码"></@s.textfield>
						</td><td class="label">
						<strong>类型:</strong>
						</td><td>
                    	<select name="type.id" >
                    		<option value="">--</option>
                    		<#list service.queryParaTypes() as type>
                        	<option value="${type.id}">${type.desc}</option>
                        	</#list>
                        </select>
						</td><td>
						<@s.submit cssClass="btn" label="增加" value="增加"></@s.submit>
						</td><td></tr></table>
	</@s.form>
	</div>
	
			<#-- 获取参数列表用于展示 -->
	<#assign heads=["id","名称","类型","编码"] />
	<#assign cols=["id","desc","type.desc","code"] />
	<#assign rows=result.list/>
	<#assign isEditable=true/>
	<@component.table "企业参数信息管理" "dataTable" heads rows cols isEditable>
     </@component.table>
</@frame>